/*
 * @Author: chenr 526963089@qq.com
 * @Date: 2023-02-10 14:55:29
 * @LastEditors: chenr 526963089@qq.com
 * @LastEditTime: 2023-03-01 14:59:49
 * @Description:
 */
import { shallowRef } from 'vue';
import { BasicLayout, RouterView } from '../layouts';
import type { RouterInterface } from '@/router/types';

/**
 * @description:  路由映射表
 * @return {*}
 */
export const constantRouterComponents: any = {
  PageView: RouterView,
  RouterView: RouterView,
  Home: () => import('@portal/views/Home/index.vue'),
  Test01: () => import('@portal/views/test/01/index.vue'),
  Test02: () => import('@portal/views/test/02/index.vue'),
  Test03: () => import('@portal/views/test/03/index.vue'),
  Test04: () => import('@portal/views/test/04/index.vue'),
};

/**
 * @description: 根级菜单
 * @return {*}
 */
export const rootRouter: RouterInterface = {
  path: '/portal',
  redirect: '/portal/home',
  meta: { title: '工作台' },
  component: shallowRef(BasicLayout),
  children: [],
};
